<!doctype html>  
<head>		
<script type='text/javascript' src='http://ajax.googleapis.com/ajax/libs/jquery/1.5.2/jquery.min.js?ver=1.5.2'></script>


	<script type="text/javascript" src="../scripts/Galeria/jquery.jcarousel.min.js"></script>
		
		
		<script src="../scripts/Galeria/jquery.nivo.slider.js" type="text/javascript"></script>
		
		<script type="text/javascript">
			$(document).ready(function() {
				$('#slider').nivoSlider({
					effect: 'fade',
					controlNav: false,
					animSpeed: 500,
					pauseTime: 3000,
					controlNav:false,
					pauseOnHover: true,
					prevText: 'Anterior', 
					nextText: 'Siguiente'
				});
				$('#slider2').nivoSlider({
					effect: 'fade',
					controlNav: false,
					animSpeed: 100,
					pauseTime: 4000,
					controlNav:false,
					prevText: 'Anterior', 
					nextText: 'Siguiente'
				});
			});
		</script>

							<script type="text/javascript"> 
					$(function() { 
					$('#galeria a').lightbox(); 
						});
				</script>
			
			 			<script src="../scripts/Galeria/galleria-1.2.9.min.js"></script>
	<script>
	Galleria.loadTheme('../scripts/Galeria/galleria.twelve.min.js');
	Galleria.configure({
		imageCrop: false,
		autoplay: 2000,
		_locale: {
			show_thumbnails: "Mostrar miniaturas",
			hide_thumbnails: "Ocultar miniaturas",
			play: "Play slideshow",
			pause: "Pausar slideshow",
			next: "Siguiente",
			prev: "Anterior",
			enter_fullscreen: "Pantalla completa",
			exit_fullscreen: "Salir de pantalla completa",
			popout_image: "Lightbox",
			showing_image: "Mostrando foto %s de %s"
			}

	});
	Galleria.run('#galleria');
	</script>
			<style>
				#galleria{height:380px}
			</style>
						
	</head>
	
<body topmargin="0" leftmargin="0">
	
		
		<div id="container">
			
		  <header role="banner"><!-- end #inner-header -->
			
			</header> 
		  <!-- end header -->
			
		  <div id="content" class="clearfix">
			
			<div id="main" class="col600 left clearfix arreglo-right" role="main">
					
							<div class="featimg">
							  
							  
  <div id="galleria">
  <?
  include("../conexion.php");
  $ID = $_GET['ID'];
 $db = conectaDb();
  $dbGaleria = $dbDb . ".GALERIA";                  // Nombre de la tabla

  
  $consulta = "SELECT * FROM $dbGaleria WHERE $dbGaleria.IDNOTA = :id ORDER BY ID DESC";  
try {
$result = $db->prepare($consulta,array(PDO::ATTR_CURSOR => PDO::CURSOR_SCROLL));
$result->bindParam(":id", $ID, PDO::PARAM_INT);
$result->execute();
if (!$result) {
    print "<p>Error en la consulta.</p>\n";
} else {
 foreach ($result as $array) {
					$Foto = $array['ARCHIVO'];	
					echo '<a href="http://www.estasenposse.com/GALERIAFOTOS/'.$Foto.'"><img src="http://www.estasenposse.com/GALERIAFOTOS/'.$Foto.'" data-lazy-loaded="true"/></a>';
			}
			}
  } catch (PDOException $e) {
    print $e->getMessage();
  }		
$db = null;  
  ?>  
  
					    </div>
						</header> <!-- end article header --><!-- end article section -->
							
			  </div> <!-- end #main -->
			</div> 
			<!-- end #content -->
		
		</div> <!-- end #container -->
		
<script type="text/javascript">if (!window.jQuery) document.write(unescape("%3Cscript src=\"../scripts/Galeria/jquery.min.js?ver=1.4.4\"%3E%3C/script%3E"))</script><script type="text/javascript" src="../scripts/Galeria/jquery.lightbox.min.js"></script>
<script type="text/javascript">
    jQuery(document).ready(function($){
      $.lightbox().overlay.options.style.opacity = 0.6;
      $.extend($.lightbox().options, {
        emergefrom      : "top",
        moveDuration    : 1000,
        resizeDuration  : 1000
      });
      $(".lightbox").lightbox({
        modal       : 0,
        autoresize  : 1
      });
    });
  </script>
</body>
</html>